{include file="public/header" /}
<body class="gray-bg">
<div class="wrapper wrapper-content">
    <div class="ibox float-e-margins">
        <div class="ibox-content">
            <div class="row">
                <!--搜索框开始-->

                <!--搜索框结束-->
                <!--操作框开始-->
                {if $status == 1}
                <div class="col-sm-12">
                    <div class="input-group" >
                        <button class="btn btn-primary" type="button" onclick="wk.layer_show('转货款', '{:url('huoAdd')}');">
                            <i class="fa fa-plus"></i> 转货款
                        </button>
                    </div>
                </div>
                {/if}
                <!--操作框结束-->

            </div>

            <div class="hr-line-dashed"></div>

            <div class="example-wrap">
                <div class="example">
                    <table class="layui-hide" id="test" lay-filter="testReload"></table>



                    <!--操作模板-->

                </div>
            </div>
        </div>
    </div>
</div>
<textarea id="allidsForOut" class="hidden"></textarea>
{include file="public/footer" /}
<script>
    //layui渲染数据表格
    layui.use('table', function () {
        var table = layui.table
            , form = layui.form;
        table.render({
            elem: '#test'
            , url: '{:url("Withdraw/withdrawToHuo")}'
            , response: {
                statusCode: 220 //成功的状态码，默认：0
            }
            , page: true
//            , size: 'lg' //sm小尺寸的表格 lg大尺寸
            , cellMinWidth: 150
            , limits: [5, 10, 15, 20, 25, 30]
            , limit: "{:config('pages')}"
            , loading: true
            , id: 'testReload'
            , cols: [[
//                {type: 'checkbox', fixed: 'left'}
                  {field: 'zhuan_id', width: '', title: 'ID', align: 'center'}
                , {field: 'zhuan_number', width: '', title: '数量', align: 'center'}
                , {field: 'zhuan_time', width: '', title: '时间', align: 'center'}
            ]]
        });
        $('.layuiBtn').on('click', function () {
            var type = $(this).data('type');
            active[type] ? active[type].call(this) : '';
        });
        var getIds = function () {
            var ids = [];
            var checkStatus = table.checkStatus('testReload')
                , data = checkStatus.data;
            $.each(data, function (index, item) {
                ids.push(item['withdraw_id'])
            });
            return ids;
        }
    });
</script>
</body>
</html>